package practice;

public enum EnumDemo {
    //第一遍
    MONDAY("周一","工作"),
    TUESDAY("周二","还工作"),
    WEDNESDAY("周三","接着工作"),
    THURSDAY("周四","继续工作"),
    FRIDAY("周五","还是工作"),
    SATURDAY("周六","不上班了"),
    SUNDAY("周日","休息");

    private String name;
    private String work;

    EnumDemo(String name, String work) {
        this.name = name;
        this.work = work;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getWork() {
        return work;
    }

    public void setWork(String work) {
        this.work = work;
    }

    public static void main(String[] args) {
        EnumDemo week = EnumDemo.MONDAY;
        EnumDemo[] week1 = EnumDemo.values();
        for(int i=0;i<week1.length;i++) {
            System.out.println(week1[i].getName());
            System.out.println(week1[i].getWork());
        }

        System.out.println(week.getName());
        System.out.println(week.getWork());

        switch(week) {
            case MONDAY:
                System.out.println("今天是"+week.getName()+",今天"+week.getWork());
                break;
            case TUESDAY:
                System.out.println("今天是"+week.getName()+",,今天"+week.getWork());
                break;
            case WEDNESDAY:
                System.out.println("今天是"+week.getName()+",,,今天"+week.getWork());
                break;
            case THURSDAY:
                System.out.println("今天是"+week.getName()+",,,,今天"+week.getWork());
                break;
            case FRIDAY:
                System.out.println("今天是"+week.getName()+",,,,,今天"+week.getWork());
                break;
            case SATURDAY:
                System.out.println("今天是"+week.getName()+",,,,,,今天"+week.getWork());
                break;
            case SUNDAY:
                System.out.println("今天是"+week.getName()+",,,,,,,今天"+week.getWork());
        }
    }

//    SPRING("春天","暖和"),
//    SUMMER("夏天","热死"),
//    AUTUMN("秋天","爽死"),
//    WINTER("冬天","冷死");
//
//    private String name;
//    private String feel;
//
//    public String getName() {
//        return name;
//    }
//
//    public void setName(String name) {
//        this.name = name;
//    }
//
//    public String getFeel() {
//        return feel;
//    }
//
//    public void setFeel(String feel) {
//        this.feel = feel;
//    }
//
//    EnumDemo(String name, String feel) {
//        this.name = name;
//        this.feel = feel;
//    }
//
//    public static void main(String[] args) {
//        EnumDemo season = EnumDemo.SUMMER;
//        System.out.println(season.getName());
//        System.out.println(season.getFeel());
//
//        EnumDemo[] season1 = EnumDemo.values();
//    for(int i=0;i<season1.length;i++) {
//        System.out.println(season1[i].getName());
//        System.out.println(season1[i].getFeel());
//    }
//
//        switch(season) {
//            case SPRING:
//                System.out.println(season.getName()+"真的"+season.getFeel());
//                break;
//            case SUMMER:
//                System.out.println(season.getName()+"真的."+season.getFeel());
//                break;
//            case AUTUMN:
//                System.out.println(season.getName()+"真的.."+season.getFeel());
//                break;
//            case WINTER:
//                System.out.println(season.getName()+"真的..."+season.getFeel());
//        }
//    }
}
